Apologies! You are using an outdated browser which lacks required capabilities. Please upgrade your browser to improve your experience.
Initializing. Please wait…
This Twine is a test of Twine's features.
[[Arrays]]
[[Input]]
[[Style]]
[[Variables]][[Return->Start]]
"""{{{}}}""" or <nowiki>"""</nowiki> Surround code.
{{{''}}}''Bold''{{{''}}} (Mislabeled as the word "strong".)
{{{//}}}//Italics//{{{//}}} (Mislabeled as the word "emphasis".)
{{{''//}}}''//Bold Italics//''{{{//''}}}
{{{__}}}__Underline__{{{___}}}
{{{==}}}==Strikethrough=={{{==}}}
{{{^^}}}^^Super^^{{{^^}}}script
{{{~~}}}~~Sub~~{{{~~}}}script
{{{Em--Dash}}} Em--Dash
{{{<mark>}}} <mark>Marked.</mark> {{{</mark>}}}
[[TiddlyWiki Markup|http://tiddlywiki.tiddlyspace.com/TiddlyWiki%20Markup]]
!"""!"""Header 1
!!"""!!"""Header 2
!!!"""!!!"""Header 3
!!!!"""!!!!"""Header 4
!!!!!"""!!!!!"""Header 5
!!!!!!"""!!!!!!"""Header 6
* {{{*}}} Bullet point.
** {{{**}}} Two bullets.
*** {{{***}}} Three bullets.
**** {{{****}}} Four bullets.
#"""#"""Numbered list.
#"""#"""Item two.
##"""##"""Level two.
###"""###""" Level three.
<<display Start>>[[Return->Start]]
This passage may change when it is rendered: [[Refresh->Variables]]
{{{<<nobr>>}}} Reduces spacing that can occur from coding, allowing spaced code.
{{{<<set $x to random(1, 6)>>}}} <<set $x to random(1, 6)>>
The variable $$x is currently $x.
{{{<<set $coin to either ("heads", "tails")>>}}}
<<set $coin to either ("heads", "tails")>> $coin
Fudge Dice are six-sided dice with two minus sides, two blank sides, and two plus sides. You roll four of them and total the results, then add it to any modifiers. To see each die result instead, we need more variables.
{{{<<set $r1 to random(-1, 1)>>}}} Repeat for $r2, $r3, $r4.
{{{<<set $rt to $r1 + $r2 + $r3 + $r4>>}}}
{{{$r1 + $r2 + $r3 + $r4 = $rt}}}
<<nobr>> <<set $r1 to random(-1, 1),
$r2 to random(-1, 1),
$r3 to random(-1, 1),
$r4 to random(-1, 1),
$rt to $r1 + $r2 + $r3 + $r4>> <</nobr>>
$r1 + $r2 + $r3 + $r4 = $rt
Operators: +, -, /, *, %, ()
Conditions: is, neq, >, >=, <, <=, and, or, not, eq, ()
Value macros: floor, ceil, round, min, max, abs, sign, sin, cos, tan
"""{{{<<if $r1 is 1>>One.
<<elseif $r1 is -1>>Negative one.
<<else>>Zero.<</if>>}}}"""
<<nobr>> <<if $r1 is 1>> One.
<<elseif $r1 is -1>> Negative one.
<<else>> Zero. <</if>> <</nobr>>
********** [[Refresh->Variables]]
********** [[Arrays]]
********** [[Return->Start]][[Return->Start]]
[[Variables]]
{{{<<set $array to [ 1, "two", "3", 4, "five" ]>>}}}
<<set $array to [ 1, "two", "3", 4, "five" ]>>
$array
(set: $a to (array: 1, "two", "3") + (array: 4, "five")) $a
(font: "monospace")[``(if: $a contains "3")[True](else:)[False]``]
(if: $a contains "3")[True](else:)[False]
(font: "monospace")[``(if: 3 is in $a)[True](else:)[False]``]
(if: 3 is in $a)[True](else:)[False]
(font: "monospace")[``(print: $a's 2nd)``]
(print: $a's 2nd)
(font: "monospace")[``(print: $a's 2ndlast)``]
(print: $a's 2ndlast)
(font: "monospace")[``(print: (text: $a's 1st + $a's 4th) + " units.")``]
(print: (text: $a's 1st + $a's 4th) + " units.")
(font: "monospace")[``(count: $a, "five")``]
(count: $a, "five")
(font: "monospace")[``(substring: "String", 3, 5)``]
(substring: "String", 2, 5)
(font: "monospace")[``(subarray: $a, 2, 3)``]
(subarray: $a, 2, 3)
(font: "monospace")[``(set: $tree to (a: "Elm", "Larch", "Spruce"))
(if: "Larch" is in $tree)[Number two: The larch.](else:)[That is not a tree.]``]
(set: $tree to (a: "Elm", "Larch", "Spruce"))(if: "Larch" is in $tree)[Number two: The larch.](else:)[That is not a tree.]
(font: "monospace")[``(set: $thief to (datamap: "Strength", 9, "Health", 9, "Dexterity", 12, "Intellect", 10))
(print: $thief's Strength)
(set: $thief's Health to 8)
(print: $thief)``]
(set: $thief to (datamap: "Strength", 9, "Health", 9, "Dexterity", 12, "Intellect", 10))(print: $thief's Strength)
(set: $thief's Health to 8)(print: $thief)
[[Return->Start]][[Return->Start]]
{{{<<button "Refresh" Input>><</button>>}}}
<<button "Refresh" Input>><</button>>
Number: <<nobr>><<set $n to 0>><span id="number"><<print $n>></span>
<<click "[+]">><<set $n++>><<replace "#number">><<print $n>><</replace>><</click>>
<<click "[-]">><<set $n-->><<replace "#number">><<print $n>><</replace>><</click>><</nobr>>
$check
{{{<<checkbox "$check" false true>> Check}}}
<<checkbox "$check" false true>> Check
$flavor
{{{<<radiobutton "$flavor" "pistachio">> Pistachio}}}
{{{<<radiobutton "$flavor" "coconut">> Coconut}}}
<<radiobutton "$flavor" "pistachio">> Pistachio
<<radiobutton "$flavor" "coconut">> Coconut
There is some graffiti here: $prompt
{{{<<textarea "$prompt" "Write graffiti here.">>}}}
<<textarea "$prompt" "Write graffiti here.">>
Last person to sign: $name
{{{<<textbox "$name" "Enter name">>}}}
Name: <<textbox "$name" "Enter name">>Double-click this passage to edit it.Double-click this passage to edit it.AuthorThis is a banner.This is a caption.<<print turns()>>
[[Arrays]]
[[Input]]
[[Style]]
[[Variables]]This is a subtitle.